<section id="matter" class="ml-24 mr-24">
  <hl-page-header title="素材管理"></hl-page-header>
  <!-- //搜索部分 -->
  <div class="clearfix mt-15 search-container-house border-b pb-10">
    <div class="pull-left">
      <p class="color-cfcfcf">信息检索</p>
      <div class="search-text">
        <span class="icon-Gm-search"></span>
        <input type="text" class="" v-model="keyword" placeholder="标题" />
      </div>
    </div>
    <div class="pull-left ml-24" v-if="flag">
      <p class="color-cfcfcf">素材类型</p>
      <hl-select :data="modulesList" v-model="moduleCode" width="140" @on-change="eventModule"></hl-select>
    </div>
    <div class="pull-left ml-24">
      <p style="color:#fff;">/</p>
      <hl-button @on-click="search" size="mini">查询</hl-button>
      <hl-button @on-click="reset" size="mini">重置</hl-button>
    </div>
  </div>
  <section class="br-4 flow-list-container line-height-40 global_table" style="border:1px solid #E5E5E5;margin-top: 15px">
    <div class="dy-flex border-b text-center global_table_title">
      <div class="dy-fx-1">序</div>
      <div class="dy-fx-2">标题</div>
      <div class="dy-fx-2">素材类型</div>
      <div class="dy-fx-2">备注</div>
      <div class="dy-fx-1 border-l">操作</div>
    </div>
    <div>
      <ul class="dy-flex flow-list-item text-center global_table_item" v-for="(item,index) in data" :id="item.id" style="margin:0">
        <li class="dy-fx-1">{{index+1}}</li>
        <li class="dy-fx-2">{{item.blockTitle}}</li>
        <li class="dy-fx-2">{{item.blockType}}</li>
        <li class="dy-fx-2">{{item.memo ? item.memo:'--'}}</li>
        <li class="dy-fx-1 border-l operateArea">
          <span @click="edit(item)">编辑</span>
          <span @click="gotoRegulate(item)" v-if="quanxian.indexOf('c222') > -1">管理</span>
        </li>
      </ul>
    </div>
  </section>
  <!-- 标题编辑 -->
  <div class="pop add-account-pop box-o-shadow" style="width:440px;" v-if="isEdit">
    <div class="head-pop font-16">
      <span>标题编辑</span>
      <button class="fw-close absolute" @click="isEdit = false">×</button>
    </div>
    <form id="add-user-form">
      <div class="content-pop">
        <label class="font-nm">
                    <span>标题：</span>
                    <div>
                        <input type="text" class="form-control add-account" name="account"  v-model="isEditobj.blockTitle"/>
                    </div>
                </label>
        <label class="font-nm">
                    <span>备注：</span>
                    <div>
                        <textarea type="text" class="form-control add-account" name="account" placeholder="非必填" v-model="isEditobj.memo"></textarea>
                    </div>
                </label>
      </div>
      <div class="text-center ptb-10">
        <button type="button" class="btn n-btn-primary" style="margin-right:50px" @click="sureBlockMeg">确认</button>
        <button type="button" class="btn n-btn-outline" @click="isEdit = false">取消</button>
      </div>
    </form>
  </div>
  <!-- 遮罩层 -->
  <div class="backdrop" style="" v-if="isEdit"></div>

</section>

<script src="modules/workbench/scripts/matter_regulate.js" charset="utf-8"></script>

<style media="screen">
  h4 {
    margin: 0;
  }

  .color-cfcfcf {
    color: #cfcfcf;
  }

  .search-container-house {
    position: relative;
  }

  .search-container-house .icon-turn-right {
    display: inline-block;
    transform: translate( -5px, 0) rotate(90deg);
  }

  .search-text {
    background: rgba(249, 249, 249, 1);
    height: 34px;
    position: relative;
    width: 220px;
    border-radius: 4px;
  }

  .search-text span {
    position: absolute;
    left: 8px;
    top: 0;
    line-height: 34px;
  }

  .search-text input {
    width: 100%;
    height: 100%;
    background: none;
    border: 0;
    outline: medium;
    text-indent: 25px;
  }

  .house-sharing-text span {
    background: rgba(249, 249, 249, 1);
    box-shadow: none;
    border: 0;
    color: #666;
  }

  input::-webkit-input-placeholder {
    color: #999;
  }

  input:-moz-placeholder {
    color: #999;
  }

  input:-ms-input-placeholder {
    color: #999;
  }

  label {
    display: flex;
  }

  .content-pop {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 17px 0 14px 0;
  }

  .font-nm {
    margin-top: 12px;
  }

  .font-nm>div>input {
    width: 240px;
  }

  .font-nm>div>textarea {
    width: 240px;
    height: 94px;
  }

  .operateArea span {
    color: #337ab7;
    cursor: pointer;
  }
</style>
